#define _CRT_SECURE_NO_WARNINGS 1
#include<iostream>
#include<vector>
#include<string>
#include<list>
using std::cout;
using std::cin;
using std::endl;

#include<deque>
#include"simulate_stack.hpp"
#include"simulate_queue.hpp"
#include"simulate_priority_queue.hpp"

using namespace wcz;

int main() 
{
	stack<int,std::vector<int>> st;
	st.push(1);
	st.push(2);
	st.push(3);
	st.push(4);
	st.push(5);
	st.push(6);
	st.push(7);

	while (!st.empty())
	{
		cout << " st.size()=" << st.size() << endl;
		cout << " st.top()=" << st.top() << endl<<endl;
		st.pop();
	}

	queue<int,std::list<int>> q;
	q.push(10);
	q.push(20);
	q.push(30);
	q.push(40);
	q.push(50);
	q.push(60);
	q.push(70);


	while (!q.empty())
	{
		cout << " q.size()=" << q.size() << endl;
		cout << " q.front()=" << q.front() << endl;
		cout << " q.back()=" << q.back() << endl<<endl;
		q.pop();
	}
	std::vector<int>v = { 1,2,3,4,5,6,7,8,9,10 };
	priority_queue<int> pq1(v.begin(), v.end());
	priority_queue<int,std::vector<int>,greater<int>> pq2;
	pq2.push(10);
	pq2.push(20);
	pq2.push(30);
	pq2.push(40);
	pq2.push(9);
	pq2.push(7);
	pq2.push(2);
	pq2.push(1);

	while (!pq2.empty())
	{
		cout << pq2.top() << " " << endl;
		pq2.pop();
	}

	return 0;
}